function queryRechargeCodeA(){
	document.getElementById("codeTigs").innerHTML = "";
	var codeA = document.getElementById("codeA").value;
	if(codeA==null || codeA==""){
		document.getElementById("codeAInfo").style.display = "";
		document.getElementById("codeTigs").innerHTML=rechargecodeacantempty;
//		document.getElementById("chargeCodeAB").className = "";
		return ;
	}
	
	var url  = "/recharge/queryCode.do?random="+Math.round(Math.random()*100);
	var param = {codeA:codeA};
	jQuery.post(url,param,function(data){
		var result = eval('(' + data + ')');
		if(result!=null){
			document.getElementById("codeAInfo").style.display = "";
//			document.getElementById("chargeCodeAB").className = "";
			hiddenQueryInfo();
			if(result.result == -100066){
				document.getElementById("codeTigs").innerHTML="<span class=\"red\">"+rechargecodeincorrect+"，"+youhaveonly+result.errorNum+attemptsleft+"</span>";
				return ;
			}else if(result.result == -100065){
				if(result.desc == 1){
					document.getElementById("codeTigs").innerHTML=rechargecodebeenchecked;
					return ;
				}else{
					document.getElementById("codeTigs").innerHTML=rechargecodeused;
					return ;
				}
			}else if(result.result == -100003){
				document.getElementById("codeTigs").innerHTML=accountbeenfrozen;
				return ;
			}else if(result.result == -100002){
				document.getElementById("codeTigs").innerHTML="<span class=\"red\">"+muchtimewrongquery+"</span>";
				return ;
			}else if(result.result == 0 ){
				showQueryInfo();
				document.getElementById("codeName").innerHTML=result.codea;
				document.getElementById("codeValue").innerHTML=result.desc;
				document.getElementById("codeCount").innerHTML=result.count;
				
				document.getElementById("agentName").innerHTML = result.name;
				if(result.info!=null){
					var info = eval('(' + result.info + ')');
					document.getElementById("codeExplain").style.display = "";
					document.getElementById("chageCare").style.display = "";
					/*document.getElementById("agentBank").innerHTML = info.name;
					document.getElementById("agentAddr").innerHTML = info.addr;
					document.getElementById("agentUser").innerHTML = info.user;
					document.getElementById("agentAccount").innerHTML = info.account;*/
					showAgentInfos();
				}
				document.getElementById("codeAInfo").style.display = "";
				return ;
			}
		}
	});
}

function refrushThis(){
	window.location.href =window.location.href; 
}

function showQueryInfo(){
	document.getElementById("codeTigs").innerHTML= "";
	document.getElementById("codeSpan").style.display = "";
	document.getElementById("codeValueSpan").style.display = "";
	document.getElementById("codeCountSpan").style.display = "";
	document.getElementById("codeName").style.display = "";
	document.getElementById("codeValue").style.display = "";
	document.getElementById("codeCount").style.display = "";
	
}

function showAgentInfos(){
	document.getElementById("agentNameSpan").style.display = "";
	/*document.getElementById("agentBankSpan").style.display = "";
	document.getElementById("agentAddrSpan").style.display = "";
	document.getElementById("agentUserSpan").style.display = "";
	document.getElementById("agentAccountSpan").style.display = "";*/
	
	document.getElementById("agentName").style.display = "";
	/*document.getElementById("agentBank").style.display = "";
	document.getElementById("agentAddr").style.display = "";
	document.getElementById("agentUser").style.display = "";
	document.getElementById("agentAccount").style.display = "";*/
	
}


function hiddenQueryInfo(){
	document.getElementById("codeExplain").style.display = "none";
	document.getElementById("chageCare").style.display = "none";
	document.getElementById("codeTigs").innerHTML= "";
	document.getElementById("codeSpan").style.display = "none";
	document.getElementById("codeValueSpan").style.display = "none";
	document.getElementById("codeCountSpan").style.display = "none";
	document.getElementById("codeName").style.display = "none";
	document.getElementById("codeValue").style.display = "none";
	document.getElementById("codeCount").style.display = "none";
	
	
	document.getElementById("agentNameSpan").style.display = "none";
	document.getElementById("agentBankSpan").style.display = "none";
	document.getElementById("agentAddrSpan").style.display = "none";
	document.getElementById("agentUserSpan").style.display = "none";
	document.getElementById("agentAccountSpan").style.display = "none";
	
	document.getElementById("agentName").style.display = "none";
	document.getElementById("agentBank").style.display = "none";
	document.getElementById("agentAddr").style.display = "none";
	document.getElementById("agentUser").style.display = "none";
	document.getElementById("agentAccount").style.display = "none";
}

function rechargeCode(){
	var codeA = document.getElementById("codeA").value;
	var codeB = document.getElementById("codeB").value;
	document.getElementById("codeAInfo").style.display = "";
	if(codeA==null||codeA==""){
		hiddenQueryInfo();
		document.getElementById("codeTigs").innerHTML=rechargecodeacannotempty;
//		document.getElementById("chargeCodeAB").className = "";
		return ;
	}
	if(codeB==null||codeB==""){
		hiddenQueryInfo();
		document.getElementById("codeTigs").innerHTML=rechargecodebcannotempty;
//		document.getElementById("chargeCodeAB").className = "";
		return ;
	}
	var url  = "/recharge/rechargeCode.do?random="+Math.round(Math.random()*100);
	var param = {codeA:codeA,codeB:codeB};
	jQuery.post(url,param,function(data){
		var result = eval('(' + data + ')');
		if(result!=null){
			document.getElementById("codeTigs").style.display = "";
//			document.getElementById("chargeCodeAB").className = "";
			if(result.result == -1){
				hiddenQueryInfo();
				document.getElementById("codeTigs").innerHTML=filloutallinformation;
				return ;
			}else if(result.result  == -2){
				hiddenQueryInfo();
				document.getElementById("codeTigs").innerHTML="<span class=\"red\">"+rechargecodeincorrect+"，"+depositfailed+"，"+youhaveonly+result.errorNum+attemptsleft+"</span>";
				return ;
			}else if(result.result  == -3){
				hiddenQueryInfo();
				document.getElementById("codeTigs").innerHTML=depositfailedfrozen;
				return ;
			}else if(result.result  == -4){
				hiddenQueryInfo();
				document.getElementById("codeTigs").innerHTML=depositfailedused;
				return ;
			}else if(result.result == -5){
				document.getElementById("codeTigs").innerHTML="<span class=\"red\">"+muchtimewrongquery+"</span>";
				return ; 
			}else if(result.result  > 0 ){
				hiddenQueryInfo();
				document.getElementById("codeTigs").innerHTML=depositsuccessful+result.result+yuan+"，"+contactsellerconfirm;
				setTimeout("refrushThis()", "2000"); 
				return ;
			}
		}
	});
}

//提现↓↓↓↓↓↓↓↓

function showConfirm(id,codeA,balance){
	document.getElementById("confirmCodeBId").value=id;
	
	if(document.getElementById("confirmPhoneCode")!=null){
		var code = document.getElementById("confirmPhoneCode").value="";
	}
	if(document.getElementById("confirmTotpCode")!=null){
		var code = document.getElementById("confirmTotpCode").value="";
	}
	document.getElementById("confirmCodeA").innerHTML=codeA;
	document.getElementById("confirmBalance").innerHTML=balance;
	document.getElementById("confirmTradePwd").value="";
	document.getElementById("confirmTigs").innerHTML=suretodeposit;
	dialogBoxShadow();
	document.getElementById("confirmCodeB").style.display="";
}

function closeConfirm(){
	dialogBoxHidden();
	document.getElementById("confirmCodeB").style.display="none";
}
var confirmFlag = 0 ;
function confirmRechargeCode(codeid){
	
		var codeid = document.getElementById("confirmCodeBId").value;
		var tradePwd = document.getElementById("confirmTradePwd").value;
		var phoneCode = 0;
		var totpCode = 0 ;
		if(codeid==null||codeid==""){
			document.getElementById("confirmTigs").innerHTML=depositunvaible;
			return;
		}
		if(tradePwd==null||tradePwd==""){
			document.getElementById("confirmTigs").innerHTML=transactionpasswordcantempty;
			return;
		}
		if(document.getElementById("confirmPhoneCode")!=null){
			var code = document.getElementById("confirmPhoneCode").value;
			if(code==null||code==""){
				document.getElementById("confirmTigs").innerHTML=smscannotempty;
				return ;
			}
			phoneCode = code;
		}
		if(document.getElementById("confirmTotpCode")!=null){
			var code = document.getElementById("confirmTotpCode").value;
			if(code==null||code==""){
				document.getElementById("confirmTigs").innerHTML=googlecannotempty;
				return ;
			}
			totpCode = code;
		}
		if(confirmFlag==0){
			confirmFlag = 1;
		}else{
			document.getElementById("confirmTigs").innerHTML=notrepeatedlyconfirm;
			return;
		}
		var url = "/recharge/confirmRechargCode.do?random="+Math.round(Math.random()*100);
		var param = {codeid:codeid,tradePwd:tradePwd,phoneCode:phoneCode,totpCode:totpCode};
		jQuery.post(url,param,function(data){
			confirmFlag = 0;
			var result = eval('(' + data + ')');
			if(result!=null){
				if(result.result==-1){
					document.getElementById("confirmTigs").innerHTML=rechargecodenotexist;
					return null;
				}else if(result.result==-2){
					document.getElementById("confirmTigs").innerHTML=rechargecodeinvalid;
					return; 
				}else if(result.result == -3){
					document.getElementById("confirmTigs").innerHTML=depositfailedcontact;
					return ; 
				}else if(result.result == -4){
					document.getElementById("confirmTigs").innerHTML=notoperateown;
					return ; 
				}else if (result.result== -5){
					document.getElementById("confirmTigs").innerHTML=wrongmuchtimelater;
					return ; 
				}else if(result.result == -6){
					document.getElementById("confirmTigs").innerHTML=transactionpasswordisincorrect;
					return ; 
				}else if(result.result == -8){
					document.getElementById("confirmTigs").innerHTML=googlecodeisincorrect+"，"+remaining+result.errorNum+chances3;
					return ;
				}else if(result.result == -9){
					document.getElementById("confirmTigs").innerHTML=smscodeisincorrect+"，"+remaining+result.errorNum+chances3;
					return ;
				}else if(result.result == -11){
					document.getElementById("confirmTigs").innerHTML=googlecodesformatincorrect;
					return ;
				}else if(result.result == -12){
					document.getElementById("confirmTigs").innerHTML=sscodesformatincorrect;
					return ;
				}else if(result.result == -20){
					 document.getElementById("confirmTigs").innerHTML=googlecodealreadyused;
					 return ;
				 }else if(result.result == 0){
					 var sta = document.getElementById("codeStatus1").value;
					window.location.href ="/account/withdrawCny.do?type=1&status="+sta; 
				}
			}
		});
}


function refrushConfirm(){
	var sta = document.getElementById("codeStatus1").value;
	window.location.href ="/account/withdrawCny.do?type=1&status="+sta; 
}

function codeKeyup(obj){
	var value = obj.value;
	var cny = document.getElementById("userCny").value;
	if(value!=null){
		obj.value =  checkNumberByName("codeValue");
	}
	if(value!=null&&value.toString().split(".")!=null && value.toString().split(".")[1] != null && value.toString().split(".")[1].length>0){
		obj.value = value.toString().split(".")[0];
	}
	if(Number(value)>Number(cny)){
		document.getElementById("rechargeCodeTigs").innerHTML=withdrawalcantexceedbalance;
		return ;
	}else{
		document.getElementById("rechargeCodeTigs").innerHTML="&nbsp;";
		return ;
	}
}

function createRechargeCode(){
	var cny = document.getElementById("userCny").value;
	var value = document.getElementById("codeValue").value;
	var tradePwd = document.getElementById("tradePwdCode").value;
	var phoneCode = 0 ;
	var totpCode = 0;
	if(value==null||value ==""){
		document.getElementById("rechargeCodeTigs").innerHTML=withdrawalamountcantempty;
		return ;
	}
	if(Number(value)>Number(cny)){
		document.getElementById("rechargeCodeTigs").innerHTML=withdrawalcantexceedbalance;
		return ;
	}
	if(tradePwd==null||tradePwd==""){
		document.getElementById("rechargeCodeTigs").innerHTML=transactionpasswordcantempty;
		return ;
	}
	if(document.getElementById("rechargeCodePhoneCode")!=null){
		var code = document.getElementById("rechargeCodePhoneCode");
		if(code.value == null || code.value==""){
			document.getElementById("rechargeCodeTigs").innerHTML=smscodecantempty;
			return ;
		}else{
			phoneCode =code.value;
		}
	}
	if(document.getElementById("rechargeCodeTotpCode")!=null){
		var code = document.getElementById("rechargeCodeTotpCode");
		if(code.value == null || code.value==""){
			document.getElementById("rechargeCodeTigs").innerHTML=smscodecantempty;
			return ;
		}else{
			totpCode = code.value;
		}
	}
	var url = "/recharge/createRechargeCode.do?random="+Math.round(Math.random()*100);
	var param = {phoneCode:phoneCode,totpCode:totpCode,tradePwd:tradePwd,codeValue:value,}
	jQuery.post(url,param,function(data){
		var result = eval('(' + data + ')');
		if(result!=null){
			if(result.result == -1){
				document.getElementById("rechargeCodeTigs").innerHTML="必填参数不能为空！";
				return ;
			}else if(result.result == -2){
				document.getElementById("rechargeCodeTigs").innerHTML=transactionpasswordisincorrect;
				return ;
			}else if(result.result == -3){
				document.getElementById("rechargeCodeTigs").innerHTML=accounthasbeenfrozen;
				return ;
			}else if(result.result == -4){
				document.getElementById("rechargeCodeTigs").innerHTML=haveoutstandingloans;
				return ;
			}else if(result.result == -5){
				document.getElementById("rechargeCodeTigs").innerHTML="该用户交易密码输错限制！";
				return ;
			}else if(result.result == -6){
				document.getElementById("rechargeCodeTigs").innerHTML=withdrawalexceedsbalance;
				return ;
			}else if(result.result == -8){
				document.getElementById("rechargeCodeTigs").innerHTML=googlecodeisincorrect+"，"+remaining+result.errorNum+chances3;
				return ;
			}else if(result.result == -9){
				document.getElementById("rechargeCodeTigs").innerHTML=smscodeisincorrect+"，"+remaining+result.errorNum+chances3;
				return ;
			}else if(result.result == -11){
				document.getElementById("rechargeCodeTigs").innerHTML=googlecodesformatincorrect;
				return ;
			}else if(result.result == -12){
				document.getElementById("rechargeCodeTigs").innerHTML=sscodesformatincorrect;
				return ;
			}else if(result.result == -13){
				document.getElementById("rechargeCodeTigs").innerHTML=maximumwithdrawal100w;
				return ;
			}else if(result.result == -14){
				document.getElementById("rechargeCodeTigs").innerHTML=minimumwithdrawalq100yuan;
				return ;
			}else if(result.result == -20){
				 document.getElementById("rechargeCodeTigs").innerHTML=googlecodealreadyused;
				 return ;
			 }else if(result.result == -99){
				 document.getElementById("rechargeCodeTigs").innerHTML=widthdrawlfailed;
				 return ;
			 }else if(result.result == 12){
                document.getElementById("rechargeCodeTigs").innerHTML=get$("waitsixconfirm");
             }else if(result.result == 17){
                document.getElementById("rechargeCodeTigs").innerHTML=get$("withdrawalmustlevel2");
             }else if(result.result == 16) {
                document.getElementById("rechargeCodeTigs").innerHTML=get$("withdrawalbefrezen");
			 }else if(result.result == 0 ){
				document.getElementById("codeValue").value ="";
				document.getElementById("tradePwdCode").value="";
				waitingStation("createRechargeCodeBth",insubmiting);
				if(document.getElementById("rechargeCodePhoneCode")!=null){
					document.getElementById("rechargeCodePhoneCode").value="";
				}
				if(document.getElementById("rechargeCodeTotpCode")!=null){
					document.getElementById("rechargeCodeTotpCode").value="";
				}
				 document.getElementById("rechargeCodeTigs").innerHTML="&nbsp;";
				document.getElementById("createCodeTigs").innerHTML=successful;
				setTimeout("refrushCreateCode()", "2000"); 
				
			}
		}
	});
}

function refrushCreateCode(){
	window.location.href ="/account/withdrawCny.do?type=1"; 
}

function lookupCodeB(codeA,codeCount){
	
	document.getElementById("queryCodeA").innerHTML=codeA;
	document.getElementById("queryCodeACount").innerHTML=codeCount;
	document.getElementById("codeAtoQuery").value = codeA;
	
	document.getElementById("codeADIV").style.display="";
	document.getElementById("codeBDIV").style.display="none";
	
	document.getElementById("resultCodeA").innerHTML="";
	document.getElementById("resultCodeB").innerHTML="";
	document.getElementById("resultCodeCount").innerHTML="";
	
	document.getElementById("codeBTradePwd").value = "";
	if(document.getElementById("codeBPhoneCode")!=null){
		document.getElementById("codeBPhoneCode").value= "";
	}
	if(document.getElementById("codeBPhoneCode")!=null){
		document.getElementById("codeBPhoneCode").value= "";
		document.getElementById("codeBPhoneCodeTips").innerHTML="";
	}
	if(document.getElementById("codeBTotpCode")!=null){
		document.getElementById("codeBTotpCode").value= "";
		document.getElementById("codeBPhoneCodeTips").innerHTML="";
	}
	dialogBoxShadow();
	document.getElementById("InquiryCodeB").style.display="";
}
function closeCodeB(){
	dialogBoxHidden();
	document.getElementById("InquiryCodeB").style.display="none";
}

function queryCodeB(){
	var codeA = document.getElementById("codeAtoQuery").value ;
	var tradePwd = document.getElementById("codeBTradePwd").value;
	var phoneCode = 0;
	var totpCode = 0 ;
	if(codeA==null||codeA==""){
		document.getElementById("codeBPhoneCodeTips").innerHTML="部分参数为空，请联系客服人员！";
		return ;
	}
	if(tradePwd==null||tradePwd==""){
		document.getElementById("codeBPhoneCodeTips").innerHTML=transactionpasswordcantempty;
		return ;
	}
	
	if(document.getElementById("codeBPhoneCode")!=null){
		var code = document.getElementById("codeBPhoneCode");
		if(code.value == null || code.value==""){
			document.getElementById("codeBPhoneCodeTips").innerHTML=smscodecantempty;
			return ;
		}else{
			phoneCode = code.value;
		}
	}
	if(document.getElementById("codeBTotpCode")!=null){
		var code = document.getElementById("codeBTotpCode");
		if(code.value == null || code.value==""){
			document.getElementById("codeBPhoneCodeTips").innerHTML=googlecannotempty;
			return ;
		}else{
			totpCode =code.value;
		}
	}
	
	var url = "/recharge/lookupCodeB.do?random="+Math.round(Math.random()*100);
	var param = {codeA:codeA,tradePwd:tradePwd,phoneCode:phoneCode,totpCode:totpCode};
	jQuery.post(url,param,function(data){
		var result = eval('(' + data + ')');
		if(result!=null){
			
			if(result.result == -1){
				document.getElementById("codeBPhoneCodeTips").innerHTML="必填参数不能为空！";
				return ;
			}else if(result.result == -2){
				document.getElementById("codeBPhoneCodeTips").innerHTML=transactionpasswordisincorrect;
				return ;
			}else if(result.result == -5){
				document.getElementById("codeBPhoneCodeTips").innerHTML="查询错误，非本人操作！";
				return ;
			}else if(result.result == -8){
				document.getElementById("codeBPhoneCodeTips").innerHTML=googlecodeisincorrect+"，"+remaining+result.errorNum+chances3;
				return ;
			}else if(result.result == -9){
				document.getElementById("codeBPhoneCodeTips").innerHTML=smscodeisincorrect+"，"+remaining+result.errorNum+chances3;
				return ;
			}else if(result.result == -11){
				document.getElementById("codeBPhoneCodeTips").innerHTML=googlecodesformatincorrect;
				return ;
			}else if(result.result == -12){
				document.getElementById("codeBPhoneCodeTips").innerHTML=sscodesformatincorrect;
				return ;
			}else if(result.result == -20){
				 document.getElementById("codeBPhoneCodeTips").innerHTML=googlecodealreadyused;
				 return ;
			}else if(result.result == 0 ){
				document.getElementById("codeADIV").style.display="none";
				document.getElementById("codeBDIV").style.display="";
				
				document.getElementById("resultCodeA").innerHTML=result.codeA;
				document.getElementById("resultCodeB").innerHTML=result.codeB;
				document.getElementById("resultCodeCount").innerHTML=result.balance;
			}
		}
		
		
	});
}

function chioceStar(elem){
	var _temp_value = 0;//鼠标hover时的等级value
	var choiceValue = 0;//默认选定的等级值为1
	
	//鼠标移入的时候
	jQuery("#"+elem+" li").mouseenter(function() {
		//获取当前的星级
		_temp_value = new Number(jQuery(this).attr(""+elem+""));
		showStar();
	
	//鼠标移入的时候
	}).mouseout(function(){
		hideStar();
	
	//鼠标移入的时候
	}).click(function(){
		//单击时，设定当前的选定值
		choiceValue = _temp_value;
		hideStar();
		document.getElementById(elem+"Value").value = choiceValue;
	});
	
	//星级显示
	function showStar() {
		for (var i = 1 ; i < _temp_value+1; ++i) {
			jQuery("#"+elem+""+i).addClass("choice");
		}
	}
	
	function hideStar() {
		for (var i = 5 ; i > choiceValue; --i) {
			jQuery("#"+elem+""+i).removeClass("choice");
		}
	}
}

function assessCode(id){
	var url = "/recharge/getRechargeCodeScore.do";
	var param = {codeid:id};
	jQuery.post(url,param,function(data){
		var result = eval('(' + data + ')');
		if(result!=null){
			if(result.result==-1){
				alert("参数不完整，请重新刷新页面！");
				return ;
			}else if(result.result == -2){
				alert(rechargecodenotexist);
				return ;
			}else if(result.result == 1){
				hideStar("starOne");
				hideStar("starTwo");
				hideStar("starFour");
				hideStar("starThree");
				//showStar('starOne');
				//showStar('starTwo');
				//showStar('starThree');
				//showStar('starFour');
				document.getElementById("assessCodeid").value = id;
				showComment();
				return ;
			}else if(result.result == 0 ){
				if(result.service!=0){//初始化服务类的星
					hideStar("starOne");
					for(var i = 1;i<=result.service;i++){
						jQuery("#starOne"+i).addClass("choice");
					}
					document.getElementById("starOneValue").value = result.service;
				}
				
				if(result.send != 0 ){//初始化发送类的星
					hideStar("starTwo");
					for(var i = 1 ; i<=result.send;i++){
						jQuery("#starTwo"+i).addClass("choice");
					}
					document.getElementById("starTwoValue").value = result.send;
				}
				
				if(result.confirm != 0){//初始化确认类的星
					hideStar("starThree");
					for(var i = 1 ; i<=result.confirm;i++){
						jQuery("#starThree"+i).addClass("choice");
					}
					document.getElementById("starThreeValue").value = result.confirm;
				}
				
				if(result.whole != 0){//初始化总体类的星
					hideStar("starFour");
					for(var i = 1 ; i<=result.whole;i++){
						jQuery("#starFour"+i).addClass("choice");
					}
					document.getElementById("starFourValue").value = result.whole;
				}
				document.getElementById("assessCodeid").value = id;
				showComment();
				return ;
			}
		}
		
	});
	
}

function hideStar(elem) {
	for (var i = 5 ; i > 0; --i) {
		jQuery("#"+elem+""+i).removeClass("choice");
	}
	document.getElementById(elem+"Value").value =0;
}
function showStar(elem) {
	for (var i = 1 ; i < 3+1; ++i) {
		jQuery("#"+elem+""+i).addClass("choice");
	}
	document.getElementById(elem+"Value").value =3;
}
function showComment(){
	dialogBoxShadow();
	document.getElementById("chargeComment").style.display="";
}
function closeComment(){
	dialogBoxHidden();
	document.getElementById("chargeComment").style.display="none";
}

function subAssessCode(){
	var codeid = document.getElementById("assessCodeid").value ;
	var service = document.getElementById("starOneValue").value ;
	var send = document.getElementById("starTwoValue").value;
	var confirm = document.getElementById("starThreeValue").value ;
	var whole = document.getElementById("starFourValue").value ;
	var url = "/recharge/updateRechargeCodeScore.do";
	var param = {codeid:codeid,service:service,send:send,confirm:confirm,whole:whole};
	jQuery.post(url,param,function(data){
		if(data!=null){
			if(data==-1){
				alert(rechargecodenotexist);
				closeComment();
				return;
			}else if(data == -2){
				alert("非本人操作！");
				closeComment();
				return;
			}else if(data == -3){
				alert("非完成状态，不可评价！");
				closeComment();
				return;
			}else if(data == -4){
				alert("错误评价，请联系客服人员");
				closeComment();
				return;
			}else if(data == 0 ){
				window.location.href = window.location.href;
			}
		}
		
		
	});
}

function showMore(type){
	jQuery(".nameListOne"+type+"").each(function(){
		jQuery(this).css("display","");
	});
	document.getElementById("moreBtn"+type+"").style.display="none";
}

function showAgentInfo(id,type){
	document.getElementById("infoContent"+type+"").style.display="none";
	var url ="/recharge/getAgentInfo.do";
	var param ={agentid:id};
	jQuery.post(url,param,function(data){
		var result = eval('(' + data + ')');
		if(result!=null){
			if(result.result == -1){
				alert("相关参数不完整，请重新刷新页面！");
				return;
			}else if(result.result == -2){
				alert(noinformationaboutvendor);
				return;
			}else if(result.result == 0 ){
				
				document.getElementById("agentName"+type+"").innerHTML = result.name;
				document.getElementById("agentBond"+type+"").innerHTML =  result.bond;
				if(result.qqurl != null && result.qqurl !=""){
					tr = result.onlineType;
					if(tr == 1){
						document.getElementById("agentQQ"+type+"").innerHTML =  result.qqurl+result.qq;
					}else if(tr == 0){
						qqUrl = result.qqurl;
						qqUrl = qqUrl.replace("pa.jpg", "pa1.png");
						document.getElementById("agentQQ"+type+"").innerHTML =  result.qq+qqUrl;
					}
				}else{
					document.getElementById("agentQQ"+type+"").innerHTML =  result.qq;
				}
				document.getElementById("agentUrl"+type+"").innerHTML =  "<a  href='"+result.url+"'>"+result.shopName+"</a>";
				
				
				/*document.getElementById("agentBankAddr"+type+"").innerHTML =  result.bankAddr;
				document.getElementById("agentBankUser"+type+"").innerHTML =  result.bankuser;
				document.getElementById("agentBankAccount"+type+"").innerHTML =  result.bankAccount;*/
				var banks  = result.banks;
				var str = "";
				for(var i =0 ; i<banks.length;i++){
//					str+="<li><span class=\"title\">开户行：</span><span class=\"information\">"+banks[i].name+"</span></li>";
					str+="<li><span class=\"newtitle\">"+sellerusername+"：</span><span class=\"information\" >"+banks[i].user+"</span></li>";
					str+="<li><span class=\"newtitle\">"+selleraccountnumber+"：</span><span class=\"information bold\">"+banks[i].account+"</span></li>";
				}
				document.getElementById("ulBankInfo").innerHTML=str;

				/*<li><span class="title">开户行：</span><span class="information" id="agentBankAddr2"></span></li>
				<li><span class="title">户名：</span><span class="information" id="agentBankUser2"></span></li>
				<li><span class="title">账号：</span><span class="information bold" id="agentBankAccount2"></span></li>*/
				
				
				document.getElementById("infoContent"+type+"").style.display="";
			}
		}
	});
}
